package cn.kgc.ffzw.myeat.services.impl;

import cn.kgc.ffzw.myeat.commons.Collection;

import cn.kgc.ffzw.myeat.services.MenuService;

public class MeunImpl implements MenuService {


    @Override
    public Collection getMenu(int pow) {
        Collection menu=new Collection();
        switch (pow){
            case 0:
                menu.add("查看未发货订单");
                menu.add("订单发货");
                break;
            case 1:
                menu.add("查看商品列表");
                menu.add("查看某商品");
                break;
        }
        return menu;
    }

    @Override
    public void printMenu(Collection menu) {
        System.out.println("⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐");
        int size=menu.size();
        for (int i = 0; i < size; i++) {
            System.out.println(i+1+"."+menu.get(i));
        }
        System.out.println("⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐⭐");
        System.out.println("请选择：");
    }
}
